package com.fr.report.web.ui;

import com.fr.web.Repository;
import com.fr.web.core.SessionIDInfor;

public class WebContentUtils
{
  public static final String EVENT_AFTERLOAD = "afterload";
  public static final String EVENT_STARTLOAD = "startload";
  public static final String EVENT_CELLSELECT = "cellselect";
  public static final String EVENT_TABCHANGE = "tabchange";

  public static String getContentPanel(Repository paramRepository)
  {
    return "_g('" + paramRepository.getSessionIDInfor().getSessionID() + "')";
  }

  public static String getFirstPageAction(Repository paramRepository)
  {
    return getContentPanel(paramRepository) + ".gotoFirstPage()";
  }

  public static String getPreviousPageAction(Repository paramRepository)
  {
    return getContentPanel(paramRepository) + ".gotoPreviousPage()";
  }

  public static String getNextPageAction(Repository paramRepository)
  {
    return getContentPanel(paramRepository) + ".gotoNextPage()";
  }

  public static String getLastPageAction(Repository paramRepository)
  {
    return getContentPanel(paramRepository) + ".gotoLastPage()";
  }

  public static String getCurrentPageNumberAction(Repository paramRepository)
  {
    return getContentPanel(paramRepository) + ".currentPageIndex";
  }

  public static String getTotalPageNumberAction(Repository paramRepository)
  {
    return getContentPanel(paramRepository) + ".totalPageNumber";
  }

  public static String getServerPrintAction(Repository paramRepository)
  {
    return getContentPanel(paramRepository) + ".printReportServer()";
  }

  public static String getPDFPrintAction(Repository paramRepository, boolean paramBoolean)
  {
    return getContentPanel(paramRepository) + ".pdfPrint('" + paramBoolean + "')";
  }

  public static String getAPPLETPrintAction(Repository paramRepository)
  {
    return getContentPanel(paramRepository) + ".appletPrint()";
  }

  public static String getFlashPrintAction(Repository paramRepository)
  {
    return getContentPanel(paramRepository) + ".flashPrint()";
  }

  public static String getPDFExportAction(Repository paramRepository, String paramString)
  {
    return getContentPanel(paramRepository) + ".exportReportToPDF('" + paramString + "')";
  }

  public static String getExcelExportAction(Repository paramRepository, String paramString)
  {
    return getContentPanel(paramRepository) + ".exportReportToExcel('" + paramString + "')";
  }

  public static String getWordExportAction(Repository paramRepository)
  {
    return getContentPanel(paramRepository) + ".exportReportToWord()";
  }

  public static String getPageSetupAction(Repository paramRepository)
  {
    return getContentPanel(paramRepository) + ".pageSetup()";
  }

  public static String getEmailReportAction(Repository paramRepository)
  {
    return getContentPanel(paramRepository) + ".emailReport()";
  }

  public static String getPrintPreviewAction(Repository paramRepository)
  {
    return getContentPanel(paramRepository) + ".printPreview()";
  }

  public static String getEditAction(Repository paramRepository)
  {
    return getContentPanel(paramRepository) + ".edit()";
  }

  public static String getSubmitReportFociblyAction(Repository paramRepository)
  {
    return getContentPanel(paramRepository) + ".writeReport()";
  }
}